<?php


namespace App\Http\Services;


use App\Utils\AES;

class ASEService
{
    static function encrypt($data) {
        try {
            return (new AES(config('app.aes_key')))->encrypt($data);
        } catch (\Exception $e) {
            return false;
        }
    }

    static function decrypt($data) {
        try {
            return (new AES(config('app.aes_key')))->decrypt($data);
        } catch (\Exception $e) {
            return false;
        }
    }
}
